package cn.wolfcode.crm.mapper;

import cn.wolfcode.crm.domain.SafetyMechanism;
import cn.wolfcode.crm.query.QueryObject;
import cn.wolfcode.crm.query.SafetyMechanismQueryObject;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface SafetyMechanismMapper {
    int deleteByPrimaryKey(Long id);

    int insert(SafetyMechanism entity);

    SafetyMechanism selectByPrimaryKey(Long id);

    List<SafetyMechanism> selectAll();

    int updateByPrimaryKey(SafetyMechanism entity);

    int queryForCount(QueryObject qo);

    List<SafetyMechanism> queryForList(SafetyMechanismQueryObject qo);

    int updateState(@Param("smId") Long id, @Param("state") int cooperation);

    List<SafetyMechanism> selectAllIdAndName();

}
